package net.lzzy.mapper;

import net.lzzy.entity.Comment;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface CommentMapper {

    public Comment findById(Integer id);

    public int insertComment(Comment comment);

    public int updateComment(Comment comment);

    public int deleteComment(Integer id);

    public List<Comment> findAll();

    //使用Limit实现简单分页
    public List<Comment> pageFind1(@Param("startPos") int startPos, @Param("pageSize") int pageSize);
}
